#include <stdio.h>
unsigned long amd(unsigned long i)
{
    if(i <= 1)
    {
        return 1;
    }
    return i * amd(i - 1);
}
int main()
{
    int a = 0;
    scanf("%d",&a);
    printf("resule is: %ld\n",amd(a));
    return 0;
}
